package cjq.demo.thread.ch6_8;

/**
 * Created by Administrator on 2016/5/6.
 */
public class Bank implements Runnable {
    private Account account;
    public Bank(Account account){
        this.account = account;
    }

    public void run(){
        for (int i = 0; i < 10; i++) {
            account.subtractAmount(1000);
        }
    }
}
